package com.taijihuabao.modules.service.impl;

import com.taijihuabao.common.commonutils.FileInOutPutStreamUtil;
import com.taijihuabao.modules.service.FileService;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;

/**
 * @author xiao
 */
@Service
public class FileServiceImpl implements FileService {

    /**
     * 文件路径
     */
    private final String USER_PROFILE_PATH = "src/main/resources/prove";

    @Override
    public String uploadProve(MultipartFile file) {
        FileInOutPutStreamUtil.uploadFile(file, USER_PROFILE_PATH);
        return FileInOutPutStreamUtil.getFilePathForData();
    }
}
